﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;

namespace OBUCare.Core.Models
{
    public partial class PARTS_SPECS
    {
        [DisplayName("编号")]
        public int ID { get; set; }

        [DisplayName("厂商编号")]
        public int SUPPLIER_ID { get; set; }

        [DisplayName("厂商")]

        public string SUPPLIER_NAME { get; set; }

        [DisplayName("型号")]
        [DataType(DataType.Text)]
        [StringLength(50)]
        public string SPEC_NAME { get; set; }

        [DisplayName("状态")]
        public int STATUS { get; set; }

        [DisplayName("元器件")]
        public int PARTS_ID { get; set; }

        [DisplayName("元器件")]
        public string PARTS_NAME { get; set; }

        [DisplayName("状态")]
        public string StatusText
        {
            get
            {
                if (STATUS == (int)DictTypeStatus.Normal)
                    return "正常";
                else
                    return "已作废";
            }
        }

    }
}
